package com.share.shareplatform.sharegoods.service;



import com.share.shareplatform.pojo.Goods;
import com.share.shareplatform.pojo.GoodsSpecial;
import com.share.shareplatform.pojo.Repertory;
import com.share.shareplatform.util.Result;

import java.io.IOException;
import java.util.List;
import java.util.Map;

public interface GoodsService {
    Long addOne(Goods goods);
    Integer updateOne(Goods goods);
    Integer deleteOneById(Long id);
    Integer deleteAllByIds(List<Long> ids);
    Goods findOneById(Long id);
    List<Goods> findAllByShopId(Long shopId);
    List<Goods> findPage(Integer pageIndex, Integer pageSize);
    List<Goods> findDimAllByName(String name);
    List<Goods> findAllByBrandId(Long id);
    List<Goods> findAllByTypeId(Long id);
    List<Goods>  findPageByName(String name,Integer pageIndex,Integer pageSize) throws IOException ;
    Map<Long,Goods> findAllByIdAsMap(String ids);
    /*GoodsKind*/
    Goods findSpecialOneById(Long id);
    Long addSpecialOne(GoodsSpecial goodsSpecial);
    List<GoodsSpecial> findAllSpecialByKind(String kind);
    Result findAllSpecial();
    Integer deleteOneSpecialById(Long id);

    int updateAllRepertory(List<Repertory> list);
}
